
#ifndef __REPLACE_PANEL_H__
#define __REPLACE_PANEL_H__

#include <glib.h>
#include <glib-object.h>
#include <gtk/gtk.h>
#include <gtksourceview/gtksourceview.h>
#include <gdk/gdk.h>
#include <stdlib.h>
#include <string.h>
#include "search_panel.h"

G_BEGIN_DECLS


#define TYPE_REPLACE_PANEL (replace_panel_get_type ())
#define REPLACE_PANEL(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), TYPE_REPLACE_PANEL, ReplacePanel))
#define REPLACE_PANEL_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), TYPE_REPLACE_PANEL, ReplacePanelClass))
#define IS_REPLACE_PANEL(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), TYPE_REPLACE_PANEL))
#define IS_REPLACE_PANEL_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), TYPE_REPLACE_PANEL))
#define REPLACE_PANEL_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), TYPE_REPLACE_PANEL, ReplacePanelClass))

typedef struct _ReplacePanel ReplacePanel;
typedef struct _ReplacePanelClass ReplacePanelClass;
typedef struct _ReplacePanelPrivate ReplacePanelPrivate;

struct _ReplacePanel {
	SearchPanel parent_instance;
	ReplacePanelPrivate * priv;
	GtkEntry* replace_pharse_entry;
};

struct _ReplacePanelClass {
	SearchPanelClass parent_class;
	gboolean (*on_replace) (ReplacePanel* self, GtkEntry* sender, const GdkEventKey* event);
};


ReplacePanel* replace_panel_construct (GType object_type, GtkSourceBuffer** source_buff, GtkSourceView** source_view);
ReplacePanel* replace_panel_new (GtkSourceBuffer** source_buff, GtkSourceView** source_view);
gboolean replace_panel_on_replace (ReplacePanel* self, GtkEntry* sender, const GdkEventKey* event);
void replace_panel_on_replace_pharse_entry_changed (ReplacePanel* self);
const char* replace_panel_get_replace_pharse (ReplacePanel* self);
void replace_panel_set_replace_pharse (ReplacePanel* self, const char* value);
GType replace_panel_get_type (void);


G_END_DECLS

#endif
